package pub.tbc.toolkit.http;

import java.util.List;

import org.apache.http.Header;
import org.apache.http.NameValuePair;

/**
 *
 * @author tbc tianbencai@e-eduspace.com
 * @version 1.0 {2016年3月25日 上午9:59:41}
 */
public interface HttpRequestor {

	static String CONTENT_TYPE_JSON = "application/json";

	static String CONTENT_TYPE_FORM = "application/x-www-form-urlencoded";

	MyResponse get(String url);

	MyResponse post(String url, String contentType, List<NameValuePair> body);

	MyResponse put(String url, String contentType, List<NameValuePair> body);

	MyResponse delete(String url);

	MyResponse request(String url, String method);

	MyResponse request(String url, String method, List<NameValuePair> body);

	MyResponse request(String url, String method, Header[] headers, List<NameValuePair> body);

}
